<?php

Yii::import('application.models._base.BaseUserBind');

class UserBind extends BaseUserBind
{
	public static function model($className=__CLASS__) {
		return parent::model($className);
	}
    public function primaryKey()
    {
        return 'uid';
    }
    public function getBind($uid){
        $data = array();
        $user_extend = Yii::app()->db->createCommand()
            ->from('{{user_bind}}')
            ->where('uid=:id', array(':id'=>$uid))
            ->queryAll();
        foreach($user_extend as $v){
            $data[$v['froms']] = $v;
        }
        return $data;
    }
}